<template>
	<view style="padding-bottom: 140rpx;">
		<view class="header">
			<u-navbar :border-bottom='false' back-icon-size='50' title="取消订单" title-color="#FFFFFF"
				back-icon-color="#FFFFFF" :background="background"></u-navbar>
		</view>
		<view class="orderBox">
			<view class="hotelInfo">
				<view class="left">
					<view class="name">
						深圳福田希尔顿酒店
					</view>
					<view class="address">
						会展中心 彩田路2009号瀚森大厦
					</view>
				</view>
				<view class="right">
					<u-icon name="map-fill" color="#3587F7" size="44"></u-icon>
					<text>地图</text>
				</view>
			</view>
			<view class="bedInfo">
				<view class="type">
					大床房
				</view>
				<view class="tips">
					<text>大床</text>
					<text>无早</text>
					<text>有窗</text>
					<text>可住2人</text>
				</view>
				<view class="time">
					<view class="start-time">
						<text class="date">2月25日</text>
						<text class="day">今天</text>
					</view>
					<view class="night">
						1晚
					</view>
					<view class="start-time">
						<text class="date">2月26日</text>
						<text class="day">周三</text>
					</view>
				</view>
				<view class="level">
					入住时间：14:00以后 离店时间：12:00以前
				</view>
			</view>
			<view class="checkInfo">
				<view class="label">
					入住人
				</view>
				<view class="check-ul">
					<view class="check-li">
						<view class="left">
							<view class="name">
								小桌子
							</view>
							<view class="phone">
								手机号 13569895632
							</view>
						</view>
						<view class="right">
							<u-icon name="edit-pen" color="#3587F7" size="36"></u-icon>
						</view>
					</view>
					<view class="check-li">
						<view class="left">
							<view class="name">
								小桌子
							</view>
							<view class="phone">
								手机号 13569895632
							</view>
						</view>
						<view class="right">
							<u-icon name="edit-pen" color="#3587F7" size="36"></u-icon>
						</view>
					</view>
				</view>
			</view>
		</view>
		<u-gap height="30" bg-color="#F2F2F7"></u-gap>
		<view class="why">
			<view class="label">
				退房原因
			</view>
			<view class="inputBox">
				<input type="text" placeholder="在此输入" />
			</view>
		</view>
		<view class="cancel">
			<view class="cancel-item sub">
				确认取消
			</view>
			<view class="cancel-item can">
				再想想
			</view>
		</view>
		
			<u-popup v-model="show" mode="center" border-radius="14"> 
					<view class="cancelBox" >
						<view class="title">
							温馨提示
						</view>
						<view class="tip">
							您的订单已取消，平台审核通过后退款将于1-3个工作日到账
						</view>
						<view class="subBtn" @click="show=false">
							确定
						</view>
					</view>
				</u-popup>
		
	</view>
</template>

<script>
	import utils from '@/common/utils.js' // 时间格式化
	export default {
		data() {
			return {
				show:true,
				background: {}
			}
		},
		methods:{
			navTo(url){
				uni.navigateTo({
					url:url
				})
			}
		}
	}
</script>

<style lang='scss' scoped>
	.header {
		width: 100%;
		height: 332rpx;
		background: linear-gradient(107deg, #3FA3F9 0%, #2D7BF7 100%);
	}

	.orderBox {
		width: 100%;
		height: auto;
		background: #FFFFFF;
		border-radius: 16rpx 16rpx 0px 0px;
		padding: 0 28rpx;
		margin-top: -232rpx;
		.hotelInfo {
			padding: 36rpx 0;
			display: flex;
			align-items: center;
			justify-content: space-between;
			border-bottom: 2rpx solid #F2F2F7;

			.left {
				.name {
					font-size: 32rpx;
					font-family: PingFang SC;
					font-weight: 600;
					color: #333333;
				}

				.address {
					margin-top: 16rpx;
					font-size: 28rpx;
					font-family: PingFang SC;
					font-weight: 400;
					color: #666666;
				}
			}

			.right {
				display: flex;
				flex-direction: column;
				align-items: center;
				justify-content: center;

				text {
					font-size: 28rpx;
					font-family: Segoe UI;
					font-weight: 400;
					color: #3587F7;
					margin-top: 8rpx;
				}
			}
		}

		.bedInfo {
			padding: 30rpx 0;
			border-bottom: 2rpx solid #F2F2F7;

			.type {
				font-size: 32rpx;
				font-family: PingFang SC;
				font-weight: 600;
				color: #333333;
			}

			.tips {
				margin-top: 8rpx;
				font-size: 24rpx;
				font-family: PingFang SC;
				font-weight: 400;
				color: #666666;

				text {
					margin-right: 15rpx;
				}
			}

			.time {
				display: flex;
				align-items: center;
				margin-top: 12rpx;

				.night {
					width: fit-content;
					height: 40rpx;
					background: #FFFFFF;
					border: 2rpx solid #DFDEE2;
					border-radius: 40rpx;
					font-size: 24rpx;
					font-family: Segoe UI;
					font-weight: 400;
					color: #666666;
					text-align: center;
					padding: 0 20rpx;
					margin: 0 20rpx;
				}

				.start-time {
					.date {
						font-size: 32rpx;
						font-family: Segoe UI;
						font-weight: bold;
						color: #333333;
						margin-right: 10rpx;
					}

					.day {
						font-size: 28rpx;
						font-family: Segoe UI;
						font-weight: 400;
						color: #666666;
					}
				}
			}

			.level {
				margin-top: 12rpx;
				font-size: 24rpx;
				font-family: PingFang SC;
				font-weight: 400;
				color: #333333;
			}
		}

		.checkInfo {
			padding: 20rpx 0;
			border-bottom: 2rpx solid #F2F2F7;

			.label {
				font-size: 32rpx;
				font-family: PingFang SC;
				font-weight: 600;
				color: #333333;
			}

			.check-ul {
				.check-li {
					height: 100rpx;
					display: flex;
					align-items: center;
					justify-content: space-between;

					.left {
						.name {
							font-size: 32rpx;
							font-family: Segoe UI;
							font-weight: 400;
							color: #333333;
						}

						.phone {
							margin-top: 6rpx;
							font-size: 28rpx;
							font-family: Segoe UI;
							font-weight: 400;
							color: #999999;
						}
					}
				}
			}
		}
	}
	
	.why {
		width: 100%;
		height: 176rpx;
		background-color: #FFFFFF;
		padding: 0 28rpx;
		.label {
			width: 100%;
			height: 88rpx;
			line-height: 88rpx;
			font-size: 32rpx;
			font-family: PingFang SC;
			font-weight: 600;
			color: #333333;
		}
		.inputBox {
			width: 100%;
			height: 88rpx;
			input {
				width: 100%;
				height: 100%;
				font-size: 28rpx;
				font-family: PingFang SC;
				font-weight: 400;
			}
		}
	}
	
	.cancel {
		width: 100%;
		height: 112rpx;
		background: #FFFFFF;
		margin-top: 60rpx;
		display: flex;
		align-items: center;
		justify-content: space-around;
		.cancel-item {
			width: 340rpx;
			height: 80rpx;
			border: 2rpx solid #3587F7;
			border-radius: 8rpx;
			text-align: center;
			line-height: 80rpx;
		}
		.sub {
			font-size: 28rpx;
			font-family: Segoe UI;
			font-weight: 400;
			color: #3587F7;
		}
		.can {
			font-size: 34rpx;
			font-family: Segoe UI;
			font-weight: 400;
			color: #FFFFFF;
			background: linear-gradient(180deg, #3FA3F9 0%, #2D7BF7 100%);
			border: none;
		}
	}	
	
	.cancelBox {
		width: 560rpx;
		height: 370rpx;
		background: #FFFFFF;
		border-radius: 16rpx;
		.title {
			padding-top: 34rpx;
			width: 100%;
			font-size: 34rpx;
			font-family: Segoe UI;
			font-weight: bold;
			color: #333333;
			text-align: center;
		}
		.tip {
			margin-top: 42rpx;
			padding: 0 42rpx;
			font-size: 28rpx;
			font-family: Segoe UI;
			font-weight: 400;
			color: #666666;
		}
		.subBtn {
			margin: 36rpx auto 0;
			width: 514rpx;
			height: 88rpx;
			background: #3587F7;
			border: 2rpx solid #3587F7;
			border-radius: 8rpx;
			font-size: 32rpx;
			font-family: Segoe UI;
			font-weight: 400;
			line-height: 88rpx;
			color: #FFFFFF;
			text-align: center;
		}
	}
	
</style>
